package principle.composite;

/**
 * @author malguy-wang sir
 * @create ---
 */
public class client {
    public static void main(String[] args) {
        //从大到小创建
        organizationComponent university = new university("野鸡大学","野鸡");
        //学院
        organizationComponent computer = new college("计信学院","神的领域");
        organizationComponent jt = new college("建土学院","打工的领域");
        //专业
        computer.add(new department("软件工程","神中之神"));
        jt.add(new department("土木工程","打工人"));

        university.add(computer);
        university.add(jt);
        //print
        university.print();
        System.out.println();
        computer.print();
    }
}
